package com.wander.patterns.act.observer2;

import java.util.Observable;
import java.util.Observer;

/**
 * @description:
 * @author: zhuyong
 * @create: 2019-09-11 17:28
 **/
public class ObserverA implements Observer {
    private int status;

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    @Override
    public void update(Observable o, Object arg) {
        this.status = ((ConcreteSubject)o).getStatus();
    }
}
